|
|
|
|
<Buffer type>.DecryptAsymmetricEnvelopped (Function) In french: <Type Buffer>.DécrypteAsymétriqueEnveloppé
bufACrypter est un Buffer = "Message à crypter"
bufMessageCrypté est un Buffer
sFichierCléPublique est une chaîne = fRepExe() + "\ClePublique.pem"
sMotDePasseCléPublique est une chaîne = "xxx"
bufMessageCrypté = bufACrypter.CrypteAsymétriqueEnveloppé(sFichierCléPublique, sMotDePasseCléPublique)
bufMessageCrypté est un Buffer
bufMessageDécrypté est un Buffer
sFichierCléPrivée est une chaîne = fRepExe() + "\ClePrivee.pem"
sMotDePasseCléPrivée est une chaîne = "xxx"
bufMessageDécrypté = bufMessageCrypté.DécrypteAsymétriqueEnveloppé(sFichierCléPrivée, sMotDePasseCléPrivée)
bufToEncrypt is Buffer = "Message to encrypt" bufEncryptedMessage is Buffer bufPublicKey is Buffer bufPrivateKey is Buffer (bufPrivateKey, bufPublicKey) = EncryptGenerateRSAKey(1024) // Encrypting a character string //--------------------------------------- bufEncryptedMessage = bufToEncrypt.EncryptAsymmetricEnveloped(bufPublicKey)  // Decryption  // ------------- bufEncryptedMessage is Buffer bufDecryptedMessage is Buffer  bufDecryptedMessage = bufEncryptedMessage.DecryptAsymmetricEnveloped(bufPrivateKey) Syntax
<Result> = <Content to decrypt>.DecryptAsymmetricEnveloped(<Private key file> [, <Password>])
<Result>: Buffer Decrypted content. <Content to decrypt>: Buffer Message to decrypt corresponding to the content of <Buffer type>.EncryptAsymmetricEnvelopped. <Private key file>: Character string or Buffer - Name and path of the file corresponding to the RSA private key to be used to decrypt the data. pem and p12 key formats are supported.
- Buffer containing the RSA private key to be used to decrypt the data.
<Password>: Optional character string Key file password (if required).
This page is also available for…
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|